﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;

namespace WpfViewBox
{
    /// <summary>
    /// VirtualizingSample.xaml 的交互逻辑
    /// </summary>
    public partial class VirtualizingSample : Page
    {
        public VirtualizingSample()
        {
            InitializeComponent();
            Loaded += new RoutedEventHandler(VirtualizingSample_Loaded);
        }

        void VirtualizingSample_Loaded(object sender, RoutedEventArgs e)
        {
            string[] images = System.IO.Directory.GetFiles(@"D:\Toshiba Web Camera\", "*.png", System.IO.SearchOption.AllDirectories);

            foreach (string source in images)
            {
                //wp.Children.Add(new TextBlock() { Text = source });
                 wp.Children.Add(new Image() { Source = new BitmapImage() { UriSource = new Uri(@"D:\Toshiba Web Camera\TDC UI\2D_3D_switch_guide.png") } });
            }
        }
    }
}
